{template 'header.html'}


<div class="container">
	<div class="aside">
    	
        <div class="mod">
            <div class="head">友情链接分类</div>
            <div class="body">
                {loop $datas $i $type}
                <a href="{url("?module=$module&typeid=$type[typeid]")}">{$type[name]}</a>
                {/loop}
            </div>
        </div> 
    </div>
    <div class="main">
    	<div class="mod">
            <div class="head">申请友情链接</div>
            <div class="body">
                <form name="myform" method="get" action="{url("?module=member&action=register")}">
                <table class="table_form" cellspacing="1" cellpadding="0"> 
                <tr> 
                    <th>链接类型</th>
                    <td><input type="radio" name="linktype" value="0" checked="checked" onclick="$('#logolink').hide()"> 文字链接
                    <input type="radio" name="linktype" value="1" onclick="$('#logolink').show()"> Logo链接
                    </td>
                </tr>
                <tr> 
                    <th>所属分类</th>
                    <td><select name='typeid' id='typeid' style="width:36%" 'require="true" compare=">0" datatype="compare" msg="请选择所属类别"'>
                        {loop $datas $i $type}
                        <option value='{$type[typeid]}'>{$type[name]}</option>
                        {/loop}
                        </select>
                    </td>
                </tr>
                <tr> 
                    <th>网站名称</th>
                    <td><input type="text" name="name" id="name" value="" require="true" datatype="require"  msg="<font color='red'>网站名称不能为空</font>"></td>
                </tr>
                <tr> 
                    <th>网站地址</th>
                    <td><input type="text" name="url" value="http://" size="40"></td>
                </tr>
                <tr id="logolink" style="display:none"> 
                    <th>Logo地址</th>
                    <td><input type="text"  name="logo" value="http://" size="40"></td>
                </tr>
        {if $M['enablecheckcode'] }
                <tr>
                    <th>验证码</th>
                    <td><input name="checkcodestr" type="text" size="4" id="code" require="true" datatype="require"  msgid="ccode" msg="验证码必须填写">
                      <img src="misc/checkcode/checkcode.php" id="checkcode" onclick="this.src='misc/checkcode/checkcode.php?id='+Math.random()*5;" style="cursor:pointer;" alt="验证码,看不清楚?请点击刷新验证码" align="absmiddle"/>
                      <span id="ccode"></span>
                    </td>
                </tr>
        {/if}
                <tr> 
                    <th></th>
                    <td><input type="submit" name="dosubmit" value=" 申 请 "> <input type="reset" name="reset" value=" 取 消 "> </td>
                </tr> 
                </table>
                </form>
            </div>
        </div>
    </div>
</div>



<script language="javascript">
<!--
	$('form').checkForm(1);
//-->
</script>
<!--end main-->
{template 'footer.html'}